# uncompyle6 version 3.2.3
# Python bytecode 3.6 (3379)
# Decompiled from: Python 3.6.8 |Anaconda custom (64-bit)| (default, Feb 21 2019, 18:30:04) [MSC v.1916 64 bit (AMD64)]
# Embedded file name: db\views\scans_extended.py
__author__ = "sanyi"
from sqlalchemy import *
from sqlalchemy.orm import mapper
from sqlalchemy.dialects.postgresql import UUID as C_UUID
from db.tables import metadata

ScansExtendedViewTable = Table(
    "scans_extended",
    metadata,
    Column("scan_id", C_UUID, primary_key=True),
    Column("owner_id", C_UUID),
    Column("creator_id", C_UUID),
    Column("current_session_id", C_UUID),
    Column("previous_session_id", C_UUID),
    Column("created", DateTime(true)),
    Column("target_id", C_UUID),
    Column("profile_id", C_UUID),
    Column("current_vuln_info", INTEGER),
    Column("current_vuln_low", INTEGER),
    Column("current_vuln_medium", INTEGER),
    Column("current_vuln_high", INTEGER),
    Column("current_threat", INTEGER),
    Column("current_start_date", DateTime(true)),
    Column("current_progress", INTEGER),
    Column("current_status", TEXT),
    Column("next_run", DateTime(True), index=True),
    Column("address", TEXT),
    Column("description", TEXT),
    Column("criticality", INTEGER),
    Column("deleted_at", DateTime(true)),
    Column("current_threat", INTEGER),
    Column("recurrence", TEXT),
    Column("schedule_disabled", BOOLEAN, default=False),
    Column("schedule_start_date", DateTime(true), index=True),
    Column("history_limit", INTEGER),
    Column("continuous", BOOLEAN, default=False),
    Column("report_template_id", C_UUID),
    Column("schedule_time_sensitive", BOOLEAN, default=False),
    Column("event_level", INTEGER),
)


class ScanExtendedViewRow(object):
    owner_id = None
    schedule_id = None
    target_id = None
    scan_id = None
    profile_id = None
    current_threat = None
    deleted_at = None
    schedule_start_date = None
    next_run = None
    current_start_date = None
    current_session_id = None
    current_status = None
    continuous = None
    created = None

    def __str__(self):
        return "R_scan_extended_view[%s:%s]" % (self.schedule_id, self.owner_id)

    def __repr__(self):
        return self.__str__()


mapper(ScanExtendedViewRow, ScansExtendedViewTable)
